<template>
  <div class="flow-ant-drawer-footer" :style="footerStyle">
    <zh-button type="primary"  :style="{ marginRight: '8px' }" @click="onSave">
      保存
    </zh-button>
    <zh-button  @click="onClose">
      取消
    </zh-button>
  </div>
</template>
<script lang="ts" setup name="FlowDrawerFooter">
import scale from '@/utils/deviceUtil';
// 定义子组件向父组件传值/事件
const emit = defineEmits(['save', 'close']);
const onSave=()=> {
  emit('save');
}
const onClose=()=> {
  emit('close');
}
const footerStyle=computed(() => {
  const textAlign = scale.isMobile() ? 'center' : 'left';
  return {
    'text-align': textAlign,
  };
})
</script>
